﻿using DncLite.Domain.Validations.Student;
using System;

namespace DncLite.Domain.Commands.Student
{
    public class RegisterStudentCommand : StudentCommand
    {
        public RegisterStudentCommand(string name,string email,DateTime birthDate,string phone)
        {
            Name = name;
            Email = email;
            BirthDate = birthDate;
            Phone = phone;
        }
        public override bool IsValid()
        {
            ValidationResult = new RegisterStudentCommandValidation().Validate(this);
            return ValidationResult.IsValid;
        }
    }
}
